import Vue from 'vue'
import router from './router/contractErpRelation'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import contractErpRelation from './contractErpRelation.vue'

import promise from 'es6-promise'
promise.polyfill();

Vue.use(ElementUI)
Vue.config.productionTip = false

/* eslint-disable no-new */
new Vue({
  el: '#contractErpRelation',
  router,
  components: { contractErpRelation },
  template: '<ContractErpRelation/>',
  render: h => h(contractErpRelation)
})

window.onload = function() {
  if(window.systemType=='portal'){
    var frameid = window.frameElement.id;
    var id = frameid + "_loading";
    if(parent.frames["menuframe"]!=null){
      var span = parent.frames["menuframe"].document.getElementById(id);
      span.className = '';
    }

  }
};
